package com.homework6;

import java.io.File;
import java.io.IOException;

public class demo01 {
    public static void main(String[] args) throws IOException {
        boolean newFile = new File("c:\\aaa\\b.txt").createNewFile();
        System.out.println(newFile);
        System.out.println(new File("c:\\aaa\\b.txt").length());
        System.out.println(new File("c:\\aaa\\b.txt").getName());
        System.out.println(new File("c:\\aaa\\b.txt").getPath());
        System.out.println(new File("c:\\aaa\\b.txt").getAbsolutePath());
        System.out.println(new File("c:\\aaa\\b.txt").getAbsoluteFile());
        System.out.println(new File("c:\\aaa\\b.txt").getParent());
        System.out.println(new File("c:\\aaa\\b.txt").getParentFile());
    }
}
